projects
/
project
/
luci.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2a229e5
)
luci-base: mvalue.htm: fix reading back multi value options
author
Jo-Philipp Wich
<
[email protected]
>
Sun, 7 Jul 2019 19:26:24 +0000
(21:26 +0200)
committer
Jo-Philipp Wich
<
[email protected]
>
Sun, 7 Jul 2019 19:27:00 +0000
(21:27 +0200)
Fixes: 2a229e50c ("luci-base: fix cbi mvalue templates")
Signed-off-by: Jo-Philipp Wich <
[email protected]
>
modules/luci-base/luasrc/view/cbi/mvalue.htm
patch
|
blob
|
history
diff --git
a/modules/luci-base/luasrc/view/cbi/mvalue.htm
b/modules/luci-base/luasrc/view/cbi/mvalue.htm
index d1fb8036783a5f41ce06785676ff4fde5a554d5d..97e40abfa20051a98ace0d0fb3673d07d1654822 100644
(file)
--- a/
modules/luci-base/luasrc/view/cbi/mvalue.htm
+++ b/
modules/luci-base/luasrc/view/cbi/mvalue.htm
@@
-1,6
+1,14
@@
<%+cbi/valueheader%>
+<%
+ local util = require "luci.util"
+ local values = {}
+ local value
+ for value in util.imatch(self:cfgvalue(section) or self.default) do
+ values[#values+1] = value
+ end
+%>
<div<%=attr("data-ui-widget", luci.util.serialize_json({
- "Select",
self:cfgvalue(section) or self.default
, self:choices(), {
+ "Select",
values
, self:choices(), {
id = cbid,
name = cbid,
size = self.size,